package net.lab1024.sa.admin.module.business.research.dao;

import java.util.List;
import net.lab1024.sa.admin.module.business.research.domain.entity.ResearchEntity;
import net.lab1024.sa.admin.module.business.research.domain.form.ResearchQueryForm;
import net.lab1024.sa.admin.module.business.research.domain.vo.ResearchVO;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Component;

/**
 * 科学论文 Dao
 *
 * @Author KeissCake
 * @Date 2024-09-18 21:41:14
 * @Copyright 暂无
 */

@Mapper
@Component
public interface ResearchDao extends BaseMapper<ResearchEntity> {

    /**
     * 分页 查询
     *
     * @param page
     * @param queryForm
     * @return
     */
    List<ResearchVO> queryPage(Page page, @Param("queryForm") ResearchQueryForm queryForm);

    /**
     * 更新删除状态
     */
    long updateDeleted(@Param("researchId")Integer researchId,@Param("deletedFlag")boolean deletedFlag);

    /**
     * 批量更新删除状态
     */
    void batchUpdateDeleted(@Param("idList")List<Integer> idList,@Param("deletedFlag")boolean deletedFlag);

}
